import { type App, createApp } from 'vue';
import pinia from './stores';
import ElementPlus from 'element-plus';
import zhCn from 'element-plus/es/locale/lang/zh-cn';
import 'element-plus/dist/index.css';
import AppComponent from './App.vue';
import router from './router';
import './styles/index.scss';
import ElSvg from './components/SvgIcon/ElSvg';
import './permission';
import VXETable from 'vxe-table';
import 'vxe-table/lib/style.css';

const app = createApp(AppComponent);
function useTable(app: App) {
  app.use(VXETable);
}
ElSvg(app);

app
  .use(pinia)
  .use(router)
  .use(ElementPlus, {
    locale: zhCn,
  })
  .use(useTable)
  .mount('#app');
